public class temp2 {
    public static void main(String[] args) {
        //新建数组使用arr.length方法遍历数组
        int[] arr = {1, 2, 3, 4, 5};
/*        int number = arr[0];
        System.out.println(number);
        System.out.println(arr[1]);
        arr[0]=100;
        System.out.println(arr[0]);*/
        for (int i = 0; i < arr.length; i++) {
            System.out.println(arr[i]);
        }
//        for (int i = 0; i < arr.length; i++) {
//
//        }
    }
}
